import Vue from 'vue'
import Router from 'vue-router'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      meta: {title: '测试'},
      component:() => import('@/components/index')
    },{
      path: '/register',
      meta: {title: '注册'},
      component:() => import('@/components/register')
    },


    {
      path: '/mission',
      meta: {title: '任务大厅'},
      component:() => import('@/components/mission/index'),
      redirect:'/lobby',
      children:[{
        path: '/lobby',
        meta: {title: '任务大厅'},
        component:() => import('@/components/mission/lobby/index')
      },{
        path: '/mine',
        meta: {title: '我的任务'},
        component:() => import('@/components/mission/mine/index')
      },{
        path: '/center',
        meta: {title: '个人中心'},
        component:() => import('@/components/mission/center/index')
      }]
    }


    ,{
      path: '/lobbyDetails',
      meta: {title: '任务详情'},
      component:() => import('@/components/mission/lobby/details'),
    },{
      path: '/detailsAddress',
      meta: {title: '任务详情地址'},
      component:() => import('@/components/mission/lobby/detailsAddress'),
    },{
      path: '/uploadDocuments',
      meta: {title: '上传凭证'},
      component:() => import('@/components/mission/mine/uploadDocuments')
    },{
      path: '/growthPlan',
      meta: {title: '成长计划'},
      component:() => import('@/components/mission/center/growthPlan/index')
    },{
      path: '/workpoint',
      meta: {title: '工分明细'},
      component:() => import('@/components/mission/center/workpoint/index')
    },{
      path: '/generalize',
      meta: {title: '我的推广'},
      component:() => import('@/components/mission/center/generalize/index')
    },{
      path: '/generalizeBusiness',
      meta: {title: '推广商户'},
      component:() => import('@/components/mission/center/generalize/generalizeBusiness')
    },{
      path: '/lookJunior',
      meta: {title: '查看下级'},
      component:() => import('@/components/mission/center/generalize/lookJunior')
    },{
      path: '/wallet',
      meta: {title: '钱包'},
      component:() => import('@/components/mission/center/wallet/index')
    },{
      path: '/extract',
      meta: {title: '提现'},
      component:() => import('@/components/mission/center/wallet/extract')
    },{
      path: '/transaction',
      meta: {title: '交易明细'},
      component:() => import('@/components/mission/center/wallet/transaction')
    },{
      path: '/bankCard',
      meta: {title: '我的银行卡'},
      component:() => import('@/components/mission/center/wallet/bankCard')
    },{
      path: '/editBankCard',
      meta: {title: '编辑银行卡'},
      component:() => import('@/components/mission/center/wallet/editBankCard')
    },{
      path: '/prize',
      meta: {title: '我的奖品'},
      component:() => import('@/components/mission/center/prize/index')
    },{
      path: '/address',
      meta: {title: '收货地址'},
      component:() => import('@/components/mission/center/address/index')
    },{
      path: '/editAddress',
      meta: {title: '编辑收货地址'},
      component:() => import('@/components/mission/center/address/editAddress')
    },








    {
      path: '/luckWheel',
      meta: {title: '幸运转盘'},
      component:() => import('@/components/publicNumber/luckyWheel/index')
    },
    {
      path: '/drawLottery',
      meta: {title: '随缘摇奖'},
      component:() => import('@/components/publicNumber/drawLottery/index')
    },
    {
      path: '/togetherReading',
      meta: {title: '好文共读'},
      component:() => import('@/components/publicNumber/togetherReading/index')
    },
    {
      path: '/togetherReadingDetals',
      meta: {title: '文章详情'},
      component:() => import('@/components/publicNumber/togetherReading/details')
    },
    {
      path: '/happyCake',
      meta: {title: '开心博饼'},
      component:() => import('@/components/publicNumber/happyCake/index')
    }
  ]
})
